package com.ysd.lis.entity.qi;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.ysd.lis.entity.BaseEntity;
import com.ysd.lis.entity.BaseEntityJpa;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

/**
 * <p>
 * 指标报表字段表
 * </p>
 *
 * @author LiuQi
 * @since 2024-01-29
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("QI_INDEX_ITEM")
@Entity
@Table(name = "QI_INDEX_ITEM")
public class QiIndexItem extends BaseEntityJpa {

    private static final long serialVersionUID = 1L;

    /**
     * 指标id
     */
    @TableField("INDEX_ID")
    @Column(name = "INDEX_ID")
    private String indexId;
    /**
     * 指标报表编码
     */
    @TableField("INDEX_CODE")
    @Column(name = "INDEX_CODE")
    private String indexCode;
    /**
     * 数据源id
     */
    @TableField("QI_DATABASE_ID")
    @Column(name = "QI_DATABASE_ID")
    private String qiDatabaseId;

    /**
     * 项目编码
     */
    @TableField("ITEM_CODE")
    @Column(name = "ITEM_CODE")
    private String itemCode;

    /**
     * 项目名称
     */
    @TableField("ITEM_NAME")
    @Column(name = "ITEM_NAME")
    private String itemName;

    /**
     * 排序号
     */
    @TableField("SEQ")
    @Column(name = "SEQ")
    private Integer seq;

    /**
     * 是否启用 1是0否
     */
    @TableField("ENABLE")
    @Column(name = "ENABLE")
    private Boolean enable;

    /**
     * 备注
     */
    @TableField("REMARK")
    @Column(name = "REMARK")
    private String remark;
    /**
     * SQL语句
     */
    @TableField("SQL_SENTENCE")
    @Column(name = "SQL_SENTENCE")
    private String sqlSentence;

    /**
     * 项目编码
     */
    @TableField("ITEM_GROUP")
    @Column(name = "ITEM_GROUP")
    private String itemGroup;

    /**
     * 统计类型 1求和,2平均值
     */
    @TableField("STAT_TYPE")
    @Column(name = "STAT_TYPE")
    private String statType;

    @TableField(exist = false)
    @Transient
    private String majorCode;


}
